bit_bang_uart.h File Reference

public methods for bit_bang_uart.c More...

Go to the source code of this file.

Defines

#define NO_CHARACTER_RECEIVED   0xFF

Functions

void bitBangOutput (unsigned char outputByte)
char bitBangInput ()

Detailed Description

public methods for bit_bang_uart.c

Rev
363
Author
dsmith
Date
2010-03-19 10:55:06 -0700 (Fri, 19 Mar 2010)
URL
http://dsmith@ns.svnrepository.com/svn/hardware/fw/ZNP%20Examples/bit_bang_uart.h

Function Documentation

char bitBangInput (  ) 

Blocking UART receiver. Called by BIT_BANG_RX_PORT Interrupt Service Routine upon detection of start bit (high to low transition). BIT_BANG_RX_BIT should be configured as high-low edge triggered interrupt. Receives a byte and then processes it.

Note:
BIT_BANG_RX_PORT, BIT_BANG_RX_BIT, DISABLE_BIT_BANG_RX_INTERRUPT(), and ENABLE_BIT_BANG_RX_INTERRUPT() must be defined. Modify accordingly for other hardware.
Precondition:
Oscillator configured for 8MHz
A high-to-low transition has occurred on BIT_BANG_RX_BIT
Returns:
the byte received
void bitBangOutput ( unsigned char  outputByte  ) 

Transmits one byte out the specified pin

To Send a Byte

  • Line is nominally at '1' (high)
  • 1 Start bit = '0'
  • Data, MSB first, LSB last. '1' = line high, '0' = line low
  • 1 Stop bit = '1' (idle, or high)
    Note:
    BIT_BANG_RX_PORT, BIT_BANG_RX_BIT, DISABLE_BIT_BANG_RX_INTERRUPT(), and ENABLE_BIT_BANG_RX_INTERRUPT() must be defined. Modify accordingly for other hardware.
    Precondition:
    Oscillator configured for 8MHz
    port/bit configured for logic output.
    bit is high (logic '1')
    Parameters:
    byte the byte to output
 All Files Functions Variables
Generated on Fri Apr 9 17:50:11 2010 for CC2530ZNP Examples by  doxygen 1.6.3